package com.atguigu.eduservice.service;

import com.atguigu.eduservice.entity.EduChapter;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * 课程章节服务接口
 * @author daygods
 * @since 2025-07-16
 */
public interface EduChapterService extends IService<EduChapter> {

    /**
     * 课程大纲列表，根据课程id进行查询
     * @param courseId 课程id
     * @return 章节列表
     */
    List<EduChapter> getChapterVideoByCourseId(String courseId);

    /**
     * 删除章节
     * @param chapterId 章节id
     * @return 是否删除成功
     */
    boolean deleteChapter(String chapterId);

    /**
     * 根据课程id删除章节
     * @param courseId 课程id
     */
    void removeChapterByCourseId(String courseId);
}